﻿package problemfactories;

import helpers.NotImplementedException;
import problems.readerswriters.*;

public class ReadersWritersFactory implements IProblemFactory<IReaderWriter>
{
    public ReadersWritersFactory()
    {
    }

    @Override
    public IReaderWriter getSolution()
    {
        return new ReaderWriterSolution();
    }

    @Override
    public IReaderWriter getSolutionWithDeadlock() throws NotImplementedException
    {
    	throw new NotImplementedException();
    }

    @Override
    public IReaderWriter getSolutionWithRaceCondition() throws NotImplementedException
    {
    	return new ReaderWriterWithRaceCondition();
    }

    @Override
    public IReaderWriter getSolutionWithDatarace() throws NotImplementedException
    {
    	return new ReaderWriterWithDataRace();
    }
}